<template>
  <div class="my-header">
    <div class="nav">
      <div class="top">
        <span>MyGame,做更懂你的游戏平台</span>
        <span>登录注册位置</span>
      </div>
      <div class="middle">
        <img src="../../public/Logo.png" alt="" />
        <div class="search">
          <div class="inp">
            <input type="text" />
            <img src="../../public/search.png" alt="" @click="goto()" />
          </div>
          <div class="hots">
            <span>热门游戏:</span>
            <a href="">弹弹堂</a>
            <a href="">圣斗士星矢</a>
            <a href="">QQ飞车</a>
            <a href="">王者荣耀</a>
          </div>
        </div>
        <div class="wxdown">
          <div>
            <img src="../../public/wx.png" alt="" />
            <p>微信客服</p>
          </div>
          <div>
            <img src="../../public/download.png" alt="" />
            <p>APP下载</p>
          </div>
        </div>
      </div>
      <div class="bottom">
        <div>
          <ul>
            <li><router-link to="/">首页</router-link></li>
            <li><router-link to="/gamecenter">游戏中心</router-link></li>
            <li><router-link to="/newgame">新游</router-link></li>
            <li><router-link to="/hot">排行榜</router-link></li>
            <li><router-link to="/giftbag">礼包中心</router-link></li>
            <li><router-link to="/information">资讯</router-link></li>
            <li><router-link to="/customer">客服中心</router-link></li>
          </ul>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  methods: {
    goto() {
      this.$router.push("/search");
    },
  },
};
</script>

<style lang="scss" scoped>
.nav {
  background-color: #fff;
}
.top {
  width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-content: center;
  border-bottom: 1px solid #eee;
  margin-bottom: 15px;
  > span {
    padding: 10px 5px;
  }
}
.middle {
  width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  cursor: pointer;
  > img {
    width: 100px;
  }
  > .search {
    flex: 1;
    margin-left: 250px;
    > .inp {
      width: 300px;
      border: 2px solid #aaa;
      border-radius: 30px;
      padding: 5px;
      input {
        width: 270px;
        line-height: px;
      }
      img {
        width: 30px;
      }
    }
    > .hots {
      margin: 3px;
      span {
        font-weight: bold;
        color: red;
        margin-right: 5px;
      }
      a {
        font-size: 0.8em;
        margin: 3px;
      }
    }
  }
  .wxdown {
    display: flex;
    div {
      margin-left: 20px;
    }
    img {
      width: 48px;
      margin-bottom: 5px;
    }
    p {
      font-size: 0.8em;
    }
  }
}
.bottom {
  > div {
    line-height: 25px;

    background-color: #404952;

    > ul {
      width: 1200px;
      margin: 0 auto;
      display: flex;
      justify-content: center;
      > li {
        height: 40px;
        cursor: pointer;
        line-height: 40px;
        padding: 5px;
        width: 150px;
        text-align: center;
        a {
          color: white;
        }
      }
      li:hover {
        transition: 0.3s;
        background-color: #cc4e5a;
      }
    }
  }
}
</style>
